/*
 Navicat Premium Data Transfer

 Source Server         : test_db
 Source Server Type    : MySQL
 Source Server Version : 80032 (8.0.32)
 Source Host           : localhost:3306
 Source Schema         : db2

 Target Server Type    : MySQL
 Target Server Version : 80032 (8.0.32)
 File Encoding         : 65001

 Date: 08/07/2023 11:44:47
*/

SET NAMES utf8mb4;
SET FOREIGN_KEY_CHECKS = 0;

-- ----------------------------
-- Table structure for config
-- ----------------------------
DROP TABLE IF EXISTS `config`;
CREATE TABLE `config` (
  `id` bigint NOT NULL AUTO_INCREMENT,
  `key_code` varchar(200) NOT NULL,
  `key_name` varchar(200) NOT NULL,
  `value_name` varchar(200) NOT NULL,
  `value_code` varchar(200) NOT NULL,
  `remark` varchar(300) DEFAULT '',
  PRIMARY KEY (`id`,`key_code`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;

-- ----------------------------
-- Records of config
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for SYS_ROLE
-- ----------------------------
DROP TABLE IF EXISTS `SYS_ROLE`;
CREATE TABLE `SYS_ROLE` (
  `ID` bigint NOT NULL AUTO_INCREMENT,
  `ROLE_NAME` varchar(200) NOT NULL DEFAULT '',
  `ROLE` varchar(200) NOT NULL DEFAULT '',
  `REMARK` varchar(400) DEFAULT '',
  `CHANGE_TIME` bigint NOT NULL DEFAULT '1',
  `LAST_TIME` bigint NOT NULL DEFAULT '1',
  PRIMARY KEY (`ID`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;

-- ----------------------------
-- Records of SYS_ROLE
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for SYS_USER
-- ----------------------------
DROP TABLE IF EXISTS `SYS_USER`;
CREATE TABLE `SYS_USER` (
  `ID` bigint NOT NULL AUTO_INCREMENT,
  `USER_NAME` varchar(200) NOT NULL DEFAULT '',
  `PASS_WORD` varchar(500) NOT NULL DEFAULT '',
  `ENABLED` tinyint NOT NULL DEFAULT '1',
  `HAS_ACCOUNT_NON_LOCK` tinyint NOT NULL DEFAULT '1',
  `HAS_ACCOUNT_NON_EXPIRED` tinyint NOT NULL DEFAULT '1',
  `HAS_CREDENTIAL_NON_EXPIRED` tinyint NOT NULL DEFAULT '1',
  `CHANGE_TIME` bigint NOT NULL DEFAULT '0',
  `LAST_TIME` bigint NOT NULL DEFAULT '0',
  PRIMARY KEY (`ID`)
) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;

-- ----------------------------
-- Records of SYS_USER
-- ----------------------------
BEGIN;
INSERT INTO `SYS_USER` (`ID`, `USER_NAME`, `PASS_WORD`, `ENABLED`, `HAS_ACCOUNT_NON_LOCK`, `HAS_ACCOUNT_NON_EXPIRED`, `HAS_CREDENTIAL_NON_EXPIRED`, `CHANGE_TIME`, `LAST_TIME`) VALUES (1, 'ldc', '$2a$10$XGFk/XQeztTcRzcQP1kezO4Gh5ZvFK5jNe/icON/SN1ngzu.ovbpS', 1, 1, 1, 1, 0, 0);
COMMIT;

-- ----------------------------
-- Table structure for SYS_USER_ROLE
-- ----------------------------
DROP TABLE IF EXISTS `SYS_USER_ROLE`;
CREATE TABLE `SYS_USER_ROLE` (
  `ID` bigint NOT NULL AUTO_INCREMENT,
  `USER_ID` bigint NOT NULL,
  `ROLE_ID` bigint NOT NULL,
  `REMARK` varchar(400) DEFAULT '',
  `CHANGE_TIME` bigint NOT NULL DEFAULT '1',
  `LAST_TIME` bigint NOT NULL DEFAULT '1',
  PRIMARY KEY (`ID`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;

-- ----------------------------
-- Records of SYS_USER_ROLE
-- ----------------------------
BEGIN;
COMMIT;

SET FOREIGN_KEY_CHECKS = 1;
